This Clipbook library demonstrates how text can be captured from the Windows Clipboard and formatted. It optionally uses spoken messages to indicate what it is doing in the background. You can download these message sound files by double-clicking on the "Download sounds" Clip.
The example used in this library will format an e-mail message by quoting the text for reply (some E-mail programs handle reply-formatting very poorly, but NoteTab can help).
When this library is activated by double-clicking on the "Start" Clip, NoteTab will capture all text sent to the Clipboard. The way the Clip has been designed, you should first copy the name of the person who sent you the E-mail, then copy the part of the message you want to reply to. The formatted reply text is then stored in the Windows Clipboard -- ready to be pasted into a new E-mail message.
Double-click on the "Stop" Clip or close the library when you have finished capturing E-mails, otherwise any text you copy to the Clipboard will continue to be processed by NoteTab.
H=";"
H="Download sounds"
^!Continue This command will activate your web browser and download the sample sound files used in this library. Continue?
^!URL http://www.notetab.com/ftp/clipwavs.zip
^!INFO Once the file has been downloaded to your computer, just unzip its content into the following subdirectory: "^$GetSoundPath$"
H=";"
H="Start"
;Show Clip wizard and ask user if long message lines should be split
^!Set %UseColumnWrap%=^?{Limit width of lines?==_Yes|No}; %Columns%=^?{If limit width, maximum line length=68}
;Set initial values for main variables
^!Set %CheckClipboard%=True; %PasteInfo%=0
^!Prompt Capture mode is now enabled
H="Stop"
;Stop checking the Windows Clipboard
^!Set %CheckClipboard%=False
^!Prompt Clipboard capturing stopped. Double-click on the "Start" Clip if you want to continue
H=";"
H="_OnOpen"
;Check if this library has been opened before. If it has, skip the instructions below
^!If ^$GetValue(efoFormatEmail)$ = 1 Exit
;Save key value to NoteTab's INI file
^!SaveValue efoFormatEmail=1
;Show instructions contained in the "About this library" Clip
^!Clip "About this library"
H="_OnClipboardChange"
;If we are not supposed to check the Windows Clipboard, end this Clip
^!IfFalse ^%CheckClipboard% End
;Copy Clipboard text into a variable
^!Set %ClipboardText%=^$GetClipboard$
;Check if Clipboard text should contain name of author or message text. If we already have the name of author, take the message text and format it, otherwise jump to the AddName label
^!IfTrue ^%FormatMessage% AddMessage ELSE AddName
:AddMessage
;Set the FormatMessage variable to 0 to indicate that the next text copied to the Clipboard should correspond to name of author
^!Set %FormatMessage%=0
;If user does not want to split lines, jump to MessageToClipboard label
^!IfTrue ^%UseColumnWrap% Next ELSE MessageToClipboard
;Add quote character to the start of each line, then add the author name at the start of the message, and finally copy the resulting text to the Clipboard -- ready for pasting in a new E-mail message